<%@ page pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/views/includes/directives/page.jspf"%>
<%@ include file="/WEB-INF/views/includes/directives/taglib.jspf"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>

<link rel="StyleSheet" href="css/general.css" type="text/css">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title><fmt:message key="users_list_jsp.title" /></title>

</head>
<body>
	<div id="main_container">
		<%@ include file="/WEB-INF/views/includes/header.jspf"%>
		<div id="content">


			<br />

			<c:forEach items="${usersOrderBean}" var="usersOrder">
				<h3>Order</h3>
				<table border='1'>
					<tr>
						<td>Order id</td>
						<td>User id</td>
						<td>Order date</td>
						<td>Status</td>
					</tr>
					<tr>
						<td>${usersOrder.orderId}</td>
						<td>${usersOrder.userName}</td>
						<td>${usersOrder.orderDate}</td>
						<td>${usersOrder.status}</td>
					</tr>
				</table>
				<br />
				<h3>Items in order</h3>
				<br />
				<table border='1'>
					<tr>
						<td>Item id</td>
						<td>Item quantity</td>
					</tr>
					<c:forEach items="${usersOrder.itemsInOrder}" var="item">

						<tr>
							<td>${item.itemId}</td>
							<td>${item.itemQuantity}</td>
						</tr>
					</c:forEach>
				</table>
				<hr />
			</c:forEach>
		</div>
		<div id="free_space"></div>
	</div>

	<%@ include file="/WEB-INF/views/includes/footer.jspf"%>
</body>
</html>